<template>
  <div>
    <div class="report">
      <!-- v-for="item in list" :key="item.id" -->
      <div class="report_item" v-for="item in list" :key="item.id">
        <div class="report_item_left">
          <div
            class="report_item_left_title"
            style="
              width: 100%;
              display: flex;
              justify-content: space-between;
              position: relative;
            "
          >
            <div class="text1" style="width:80%; margin-bottom: 0">
              {{ item.businessType == 1 ? "房源位置：" : "车辆地址："
              }}{{ item.position }}
            </div>
          </div>
          <div>联系电话：{{ item.contactInformation }}</div>
          <div>委托时间：{{ item.createDate }}</div>
          <div style="word-break: break-all;">备注：{{ item.remarks }}</div>
        </div>
      </div>
    </div>
  </div>
</template>

<script>
export default {
  props: {
    types: {
      type: String
    },
    list: {
      type: Array,
      default() {
        return [];
      }
    }
  },
  data() {
    return {
      // list:[]
    };
  },
  methods: {
    // 撤销委托
    cancelPowerAttorney(item) {
      this.$postHttp("/api/mobile/public/revocationDelegation", {
        userId: JSON.parse(localStorage.getItem("userInfo")).id,
        id: item.id
      }).then(res => {
        if (res.code == 200) {
          this.mySuccessMessage(res.msg);
          this.$emit("refresh");
        }
      });
    }
  }
};
</script>

<style lang="less" scoped>
.text1 {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
div,
span {
  color: #333333;
}
.report_item_left_title {
  font-size: 22px;
  font-weight: 500;
  color: #333333;
}
.report {
  display: flex;
  flex-direction: column;
  .report_itemse {
    width: 100%;
    box-sizing: border-box;
    height: 200px;
    padding: 25px 35px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    border-bottom: 10px solid #f2f2f2;
  }
  .report_item {
    width: 100%;
    // height: 200px;
    box-sizing: border-box;
    padding: 25px 35px;
    // display: flex;
    // justify-content: space-between;

    align-items: flex-start;
    border-bottom: 10px solid #f2f2f2;
    .report_item_left {
      flex: 4;
      display: flex;
      flex-direction: column;
      div {
        margin-bottom: 12px;
      }
    }
    .withdraw {
      flex: 1;
      position: absolute;

      top: 50%;
      right: 20px;
      transform: translateY(-50%);
      .withdraw_item {
        width: 120px;
        height: 42px;
        border: 1px solid #64b6a8;
        border-radius: 20px;
        font-size: 19px;
        font-weight: 400;
        color: #64b6a8;
        text-align: center;
        line-height: 42px;
        cursor: pointer;
        margin: 0 auto;
      }
    }
  }
}
</style>
